package com.ruicar.afs.cloud.risk.tortoise.dto.response.apply;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.ruicar.afs.cloud.risk.tortoise.anno.RefData;
import com.ruicar.afs.cloud.risk.tortoise.dto.response.GwtRefData;
import io.swagger.annotations.ApiModel;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @Description
 * @Author Peng Jinbo
 * @Date 2020/07/27 18:39
 */
@Data
@AllArgsConstructor
@Builder
@ApiModel("挂靠信息 - caanchoredinfo")
public class GwtAffiliated extends GwtRefData implements Serializable {


    /**
     * Legal person phone
     */
    @JsonInclude
    @JSONField(name = "legalpersonphone")
    @JsonProperty("legalpersonphone")
    private String legalPersonPhone;

    /**
     * Legal person name
     */
    @JsonInclude
    @JSONField(name = "legalperson")
    @JsonProperty("legalperson")
    private String legalPersonName;

    /**
     * Enable
     */
    @JsonInclude
    @RefData(dicKey = "isType", translatedKey = "whetherStatus")
    @JSONField(name = "status")
    @JsonProperty("status")
    private String enable;

    /**
     * Register date
     */
    @JsonInclude
    @JSONField(name = "registeredtime",format = "yyyy-MM-dd HH:mm:ss ")
    @JsonProperty("registeredtime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date registerDate;

    /**
     * Company phone
     */
    @JsonInclude
    @JSONField(name = "phone")
    @JsonProperty("phone")
    private String companyPhone;

    /**
     * Affiliated mode
     */
    @JsonInclude
    @RefData(dicKey = "affiliatedWay")
    @JSONField(name = "affiliatedmode")
    @JsonProperty("affiliatedmode")
    private String affiliatedMode;

    /**
     * Company name
     */
    @JsonInclude
    @JSONField(name = "affiliatedcompany")
    @JsonProperty("affiliatedcompany")
    private String companyName;

    /**
     * Company province
     */
    @JsonInclude
    @RefData(useFieldName = true)
    @JSONField(name = "gkcompanyprovince")
    @JsonProperty("gkcompanyprovince")
    private String companyProvince;

    /**
     * Company province name
     */
    @JsonIgnore
    @JSONField(serialize = false)
    private String companyProvinceName;

    /**
     * Company city
     */
    @JsonInclude
    @RefData(useFieldName = true)
    @JSONField(name = "gkcompanycity")
    @JsonProperty("gkcompanycity")
    private String companyCity;

    /**
     * Company city name
     */
    @JsonIgnore
    @JSONField(serialize = false)
    private String companyCityName;
}
